% convex_cost_barlevy.m
%
% plot CDF and PDF of convex cost function used in Barlevy and Jermann
%

%ppsi = 0.163720370670608;
%theta = 0.5;

ppsi = 0.00691645130700432;
theta = 0.9;

in = 0:0.001:0.05;

gi = kap*in + (ppsi/(1-theta)).*(in.^(1-theta));
dgi = kap + ppsi.*(in.^(-theta)); 


figure (1)

subplot(1,2,1)
plot(in,gi)
title('g')

subplot(1,2,2)
plot(in,dgi)
title('dg')

